package com.ruoyi.business.service.impl;

import java.util.List;
import com.ruoyi.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.business.mapper.SysComponentParametersMapper;
import com.ruoyi.business.domain.SysComponentParameters;
import com.ruoyi.business.service.ISysComponentParametersService;

/**
 * 系统组件参数Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-11-18
 */
@Service
public class SysComponentParametersServiceImpl implements ISysComponentParametersService 
{
    @Autowired
    private SysComponentParametersMapper sysComponentParametersMapper;

    /**
     * 查询系统组件参数
     * 
     * @param id 系统组件参数主键
     * @return 系统组件参数
     */
    @Override
    public SysComponentParameters selectSysComponentParametersById(Long id)
    {
        return sysComponentParametersMapper.selectSysComponentParametersById(id);
    }

    /**
     * 查询系统组件参数列表
     * 
     * @param sysComponentParameters 系统组件参数
     * @return 系统组件参数
     */
    @Override
    public List<SysComponentParameters> selectSysComponentParametersList(SysComponentParameters sysComponentParameters)
    {
        return sysComponentParametersMapper.selectSysComponentParametersList(sysComponentParameters);
    }

    /**
     * 新增系统组件参数
     * 
     * @param sysComponentParameters 系统组件参数
     * @return 结果
     */
    @Override
    public int insertSysComponentParameters(SysComponentParameters sysComponentParameters)
    {
        sysComponentParameters.setCreateTime(DateUtils.getNowDate());
        return sysComponentParametersMapper.insertSysComponentParameters(sysComponentParameters);
    }

    /**
     * 修改系统组件参数
     * 
     * @param sysComponentParameters 系统组件参数
     * @return 结果
     */
    @Override
    public int updateSysComponentParameters(SysComponentParameters sysComponentParameters)
    {
        sysComponentParameters.setUpdateTime(DateUtils.getNowDate());
        return sysComponentParametersMapper.updateSysComponentParameters(sysComponentParameters);
    }

    /**
     * 批量删除系统组件参数
     * 
     * @param ids 需要删除的系统组件参数主键
     * @return 结果
     */
    @Override
    public int deleteSysComponentParametersByIds(Long[] ids)
    {
        return sysComponentParametersMapper.deleteSysComponentParametersByIds(ids);
    }

    /**
     * 删除系统组件参数信息
     * 
     * @param id 系统组件参数主键
     * @return 结果
     */
    @Override
    public int deleteSysComponentParametersById(Long id)
    {
        return sysComponentParametersMapper.deleteSysComponentParametersById(id);
    }
}
